/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

function addAuthorValidation()
{
    var firstName = document.forms["frm_addAuthor"]["txtAuthorFirstName"].value;
    var lastName = document.forms["frm_addAuthor"]["txtAuthorLastName"].value;
    
    if (firstName=="")
        {
            alert("Please Enter Author's First Name");
            return false;
        }
        
    if (lastName=="")
        {
            alert("Please Enter Author's Last Name");
            return false;
        }
}

function validateAuthor(frm_name, txt_firstNameField, txt_lastNameField)
{
    var firstName = document.forms[frm_name][txt_firstNameField].value;
    var lastName = document.forms[frm_name][txt_lastNameField].value;
    
    if (firstName=="")
        {
            alert("Please Enter Author's First Name");
            return false;
        }
        
    if (lastName=="")
        {
            alert("Please Enter Author's Last Name");
            return false;
        }
}